package com.ldgame.utils;

import com.ldgame.game.Game;
import com.ldgame.game.RunningState;

public class NewGameAction implements BtnAction {
	private Game game;
	
	public NewGameAction(Game game) {
		this.game = game;
	}
	
	@Override
	public void executeAction() {
		if (game.getRunningGame() == null) {
			game.setRunningGame(new RunningState(game));
		}
		game.setGameState(game.getRunningGame());
	}
}
